//
//  ArrayToDic.h
//  CocoaMoney
//
//  Created by Daniel Braun on 01/10/06.
//  Copyright 2006 Daniel Braun http://braun.daniel.free.fr. All rights reserved.
//
/*!
    @header DictionaryWrapper
    @abstract   provide a Array, suitable for UI display, from a dictionnary
    @discussion array elements are DictionaryWrapper, which is a pair of key/value item
*/


#ifdef TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif

/*!
    @class
    @abstract    key/value pair
    @discussion  used as array elements when wrapping a dictionnary to an array
*/

@interface DictionaryWrapper : NSObject {
	id key;
	id value;
}

/*!
    @method     
    @abstract   (brief description)
    @discussion (comprehensive description)
*/
- (id)key;

	/*!
	@method     
	 @abstract   (brief description)
	 @discussion (comprehensive description)
	 */
- (void)setKey:(id)value;

	/*!
	@method     
	 @abstract   (brief description)
	 @discussion (comprehensive description)
	 */
- (id)value;

- (NSString *) stringValue;

	/*!
	@method     
	 @abstract   (brief description)
	 @discussion (comprehensive description)
	 */
- (void)setValue:(id)value;


	/*!
	@method     
	 @abstract   (brief description)
	 @discussion (comprehensive description)
	 */
+ (NSMutableArray *) arrayFromDictionary:(NSDictionary *)dic;

	/*!
	@method     
	 @abstract   (brief description)
	 @discussion (comprehensive description)
	 */
+ (NSMutableDictionary *) dictionaryFromArray:(NSArray *)array;

- (NSString *) vclassName;


@end

